#pragma once
#include "dxManager.h"
#include "map.h"
#include "Block.h"
#include <windows.h>
#include <conio.h>		// getch()
#include <stdio.h>
#include <time.h>
#include <iostream>

using namespace std;

class Game
{
private:
	Map m;
	Block b;
	dxManager Dx;
	//char** temp;
	bool CheckFullFlag;
	bool CheckCollision;
	int input;
	int BlockX, BlockY;
public:
	void Move();
	void Collision(char** BlockFiles);
	Game(int BlockX, int BlockY, char* a_filename, char** BlockFiles);
	~Game();
	void DrawBlock(int BlockX, int BlockY);
	void Zeroize(char** BlockFiles);
	void update(char** BlockFiles);
	int RandomBlock(char** BlockFiles);
	void gotoxy(int x, int y);
	void Draw(int x, int y);
	void RotateCW();
	void GetInput();
	bool IsStillRunning();
	bool isWithin(int MinX, int MinY, int MaxX, int MaxY);
};